ButtonOpen SUB Action Opens a button of the specified type, and places it in the current window at the window coordinates specified. Syntax ButtonOpen handle%, state%, text$, row1%, col1%, row2%, col 2%, buttonType% Remarks Use ButtonOpen when you want to place any kind of buttons in open windows. The ButtonOpen procedure uses the following arguments. handle% ------- An integer that indicates the number of the button that is being opened. This can be any number between 1 and the value declared in the constant MAXBUTTON, inclusive. state% ------ An integer that indicates the initial state of the button that is being opened. For each different button type and state% value, the following applies. Type Value Significance 1 1 Normal. 2 Default choice (brackets highlighted). 3 Chosen (highlighted in reverse video). 2 & 3 1 Normal. 2 Selected (checked). 4 0 Does not apply to type 4 (area button). 5 Reserved for future use. 6 & 7 n Indicates the initial position of the scroll bar's position indicator. It can be between 1 and the maximum position. text$ ----- A string that contains the text to be displayed in the button. Does not apply to button types 4, 6, or 7. row1%, col1% ------------ An integer pair that describes the upper-left corner of an area relative to the upper-left corner of the current window, not the screen. row2%, col 2% ------------- An integer pair that specifies the lower-right corner of an area, relative to the upper-left corner of the current window, not the screen. The coordinates row2% and col 2% apply only to button types 4, 6, and 7. Any values in these arguments are ignored by other button types; however, arguments must be in the argument list, even if their value is 0. buttonType% ----------- An integer that indicates the type of button to be opened. The following is a list of valid button types. 1 Command button 2 Check box 3 Option button 4 Area button 5 Reserved for future use 6 Vertical scroll bar 7 Horizontal scroll bar Note that the positioning coordinates are relative to the current window, not absolute from the top-left corner of the screen. Within each window, each button has a unique handle% value. Because buttons are local to specific windows it is permissible to have more than one button with the same handle% value, provided they are in different windows. See Also. ButtonClose